package com.xwltz.core.exception;

import com.xwltz.core.domain.ActionResult;
import com.xwltz.core.domain.SimpleActionResult;

/**
 * @description BaseException
 * @information on version 1.0 be created by @xwltz at 2021/11/23 10:00
 */
@SuppressWarnings("unused")
public abstract class BaseException extends RuntimeException {
	public Integer code;
	public String message;

	public Exception e;

	public BaseException() {
	}

	public BaseException(String msg, Exception e) {
		super(msg, e);
		this.message = msg;
		this.e = e;
	}

	public BaseException(String msg) {
		super(msg);
		this.message = msg;
	}

	public abstract String getExceptionName();

	public abstract ActionResult<?> getResultInstance();

	public abstract SimpleActionResult getSimpleResultInstance();
}
